package com.qianf.qfoffice.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

public class Grade implements Serializable {

    private int id;
    private String u_no;
    private String name;
    // 1.将json 中的是将 转换为 java date
    // 2.返回json 数据可以将  date 转为  yyyy-MM-dd HH:mm:ss
    @JsonFormat(pattern="yyyy-MM-dd",timezone = "GMT+8")
    //接收对象时 将属性 yyyy-MM-dd HH:mm:ss ----》date
    @DateTimeFormat(pattern = "yyyy-MM-dd")

    private Date createtime;
    private int week;
    private String location;
    private int flag;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getU_no() {
        return u_no;
    }

    public void setU_no(String u_no) {
        this.u_no = u_no;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Date getCreatetime() {
        return createtime;
    }

    public void setCreatetime(Date createtime) {
        this.createtime = createtime;
    }

    public int getWeek() {
        return week;
    }

    public void setWeek(int week) {
        this.week = week;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public int getFlag() {
        return flag;
    }

    public void setFlag(int flag) {
        this.flag = flag;
    }

    @Override
    public String toString() {
        return "Grade{" +
                "id=" + id +
                ", u_no='" + u_no + '\'' +
                ", name='" + name + '\'' +
                ", createtime=" + createtime +
                ", week=" + week +
                ", location='" + location + '\'' +
                ", flag=" + flag +
                '}';
    }
}
